Cisco Packet Tracer Extensions API 8.1.0
API for communication between Cisco Packet Tracer application and its extension applications and modules.
Public Member Functions | List of all members
DhcpServerProcess Class Reference

DhcpServerProcess is the process that handles DHCP pools and leases. More...

Inheritance diagram for DhcpServerProcess:
Process

Public Member Functions

void addExcludedAddress (ip, ip)
 Adds a range of IP addresses to exclude. More...
 
void removeExcludedAddress (ip, ip)
 Removes the range of IP addresses to exclude. More...
 
void updateNetworkReservation (ip)
 
int getExcludedAddressCount ()
 Returns the number of address ranges that is excluded. More...
 
pair< ip, ip > getExcludedAddressAt (int)
 Returns the excluded address range at the specified index. More...
 
void addPool (string)
 Adds a DHCP pool to this process. More...
 
void addNewPool (string, string, string, string, string, int, string, string)
 Adds a new DHCP pool with the specified arguments. More...
 
DhcpPool getPool (string)
 Returns a DhcpPool object with the specified pool name. More...
 
void removePool (string)
 Removes the DHCP pool from this process. More...
 
int getPoolCount ()
 Returns the number of DHCP pools in this process. More...
 
DhcpPool getPoolAt (int)
 Returns the DHCP pool at the specified index. More...
 
bool isEnable ()
 Returns true if this DHCP server process is enabled, otherwise false. More...
 
void setEnable (bool)
 Enables or disables this DHCP server process. More...
 
- Public Member Functions inherited from Process
Device getOwnerDevice ()
 Returns the device for this process. More...
 

Detailed Description

DhcpServerProcess is the process that handles DHCP pools and leases.

Member Function Documentation

◆ addExcludedAddress()

void DhcpServerProcess::addExcludedAddress ( ip  ,
ip   
)

Adds a range of IP addresses to exclude.

Parameters
startIp,thestarting IP address.
endIp,theending IP address.

◆ addNewPool()

void DhcpServerProcess::addNewPool ( string  ,
string  ,
string  ,
string  ,
string  ,
int  ,
string  ,
string   
)

Adds a new DHCP pool with the specified arguments.

Parameters
poolName,thename for the DHCP pool.
gateway,theIP address of the default gateway.
dnsServer,theIP address of the DNS server.
startIp,thestart IP address of the DHCP pool.
subnetMask,thesubnet mask of the DHCP pool.
maxUsers,themaximum number of users for the DHCP pool.
tftpServerIp,theIP address of the TFTP server.
wlcIp,theIP address of the WLC.

◆ addPool()

void DhcpServerProcess::addPool ( string  )

Adds a DHCP pool to this process.

Parameters
poolName,thename of the DHCP pool to add.

◆ getExcludedAddressAt()

pair< ip, ip > DhcpServerProcess::getExcludedAddressAt ( int  )

Returns the excluded address range at the specified index.

Parameters
index,theindex of excluded address range of interest.
Returns
pair<ip,ip>, a pair of IP addresses, the first is the start IP address, the second is the end IP address.

◆ getExcludedAddressCount()

int DhcpServerProcess::getExcludedAddressCount ( )

Returns the number of address ranges that is excluded.

Returns
int, the number of address ranges that is excluded.

◆ getPool()

DhcpPool DhcpServerProcess::getPool ( string  )

Returns a DhcpPool object with the specified pool name.

Parameters
poolName,thename of the DHCP pool of interest.
Returns
DhcpPool, the DhcpPool object associated with the pool name.

◆ getPoolAt()

DhcpPool DhcpServerProcess::getPoolAt ( int  )

Returns the DHCP pool at the specified index.

Parameters
index,theindex of the DHCP pool of interest.
Returns
DhcpPool, the DhcpPool object at the specified index.

◆ getPoolCount()

int DhcpServerProcess::getPoolCount ( )

Returns the number of DHCP pools in this process.

Returns
int, the number of DHCP pools in this process.

◆ isEnable()

bool DhcpServerProcess::isEnable ( )

Returns true if this DHCP server process is enabled, otherwise false.

Returns
bool, true if this DHCP server process is enabled, otherwise false.

◆ removeExcludedAddress()

void DhcpServerProcess::removeExcludedAddress ( ip  ,
ip   
)

Removes the range of IP addresses to exclude.

Parameters
startIp,thestarting IP address.
endIp,theending IP address.

◆ removePool()

void DhcpServerProcess::removePool ( string  )

Removes the DHCP pool from this process.

Parameters
poolName,thename of the pool to remove.

◆ setEnable()

void DhcpServerProcess::setEnable ( bool  )

Enables or disables this DHCP server process.

Parameters
bEnable,trueto enable this DHCP server process, false to disable it.

◆ updateNetworkReservation()

void DhcpServerProcess::updateNetworkReservation ( ip  )

The documentation for this class was generated from the following file: